﻿
//有参数调用
$(document).ready(function () {
        //alert($("#ctl00_ContentPlaceHolder1_username").attr("value"));
            $("#login").click(function() {
            //alert('');
                $.ajax({
                    type: "POST",
                    contentType: "application/json",
                    url: "WebService1.asmx/GetWish",
                    data: "{username:"+$("#ctl00_ContentPlaceHolder1_username").attr("value")+",password:"+$("#ctl00_ContentPlaceHolder1_password").attr("value")+"}",
                    dataType: 'json',
                    success: function(result) {
                    if(this['result']=="success")
                    {
                        
                        document.location="/user/default.aspx";
                    }
                    else
                    {
                    
                    }

                     
                    }
                });
            });
        });
$(document).ready(function() {
            $('#loading').ajaxStart(function() {
                $(this).show();
            }).ajaxStop(function() {
                $(this).hide();
            });
        });
